package cn.com.czpb.client.model.usercenter;

import com.chad.library.adapter.base.entity.MultiItemEntity;

import java.util.List;

/**
 * Created by Administrator on 2017/8/7.
 */

public class MessageBean implements MultiItemEntity{
    public static int  TEXT_TYPE=0;
    public static int  ACTION_REPLY=3;
    /**
     * uid : 56
     * nickname : 185****
     * sex : 3
     * avatar_path : http://101.200.174.98/yunzong_jhxt/../files/app/avatar/app_logon.png
     * tid : 0
     * mediatype : 0
     * action : 3
     * create_time : 1分钟前
     * isread : 0
     * data : {"reply":"你是?","comment":"你好啊","contenttype":"1","rtype":"1","nid":"937","title":"测试","type":"5","imgs":["http://101.200.174.98/yunzong_jhxt/../../files/app/thumb/s_1501830795.jpg"]}
     */

    private String uid;
    private String nickname;
    private String sex;
    private String avatar_path;
    private String tid;
    private String mediatype;
    private String action;
    private String create_time;
    private String isread;
    private String cid;
    private String reply;

    public String getReply() {
        return reply;
    }

    public void setReply(String reply) {
        this.reply = reply;
    }

    private ReplyToEntity replyto;

    public ReplyToEntity getReplyto() {
        return replyto;
    }

    public void setReplyto(ReplyToEntity replyto) {
        this.replyto = replyto;
    }

    public String getCid() {
        return cid;
    }

    public void setCid(String cid) {
        this.cid = cid;
    }

    public void setUid(String uid) {
        this.uid = uid;
    }

    public void setNickname(String nickname) {
        this.nickname = nickname;
    }

    public void setSex(String sex) {
        this.sex = sex;
    }

    public void setAvatar_path(String avatar_path) {
        this.avatar_path = avatar_path;
    }

    public void setTid(String tid) {
        this.tid = tid;
    }

    public void setMediatype(String mediatype) {
        this.mediatype = mediatype;
    }

    public void setAction(String action) {
        this.action = action;
    }

    public void setCreate_time(String create_time) {
        this.create_time = create_time;
    }

    public void setIsread(String isread) {
        this.isread = isread;
    }



    public String getUid() {
        return uid;
    }

    public String getNickname() {
        return nickname;
    }

    public String getSex() {
        return sex;
    }

    public String getAvatar_path() {
        return avatar_path;
    }

    public String getTid() {
        return tid;
    }

    public String getMediatype() {
        return mediatype;
    }

    public String getAction() {
        return action;
    }

    public String getCreate_time() {
        return create_time;
    }

    public String getIsread() {
        return isread;
    }



    @Override
    public int getItemType() {
//        if (getAction().equals("3")) {
            return TEXT_TYPE;
//        }
//        return 0;
    }


    public static class ReplyToEntity  implements MultiItemEntity {
        /**
         * reply : 你是?
         * comment : 你好啊
         * contenttype : 1
         * rtype : 1
         * nid : 937
         * title : 测试
         * type : 5
         * imgs : ["http://101.200.174.98/yunzong_jhxt/../../files/app/thumb/s_1501830795.jpg"]
         */


        private String comment;
        private String create_time;
        private String nickname;
        private String contenttype;
        private String rtype;
        private String nid;
        private String title;
        private String type;
        private String avatar_path;
        private List<String> imgs;

        public String getCreate_time() {
            return create_time;
        }

        public void setCreate_time(String create_time) {
            this.create_time = create_time;
        }

        public String getNickname() {
            return nickname;
        }

        public void setNickname(String nickname) {
            this.nickname = nickname;
        }

        public String getAvatar_path() {
            return avatar_path;
        }

        public void setAvatar_path(String avatar_path) {
            this.avatar_path = avatar_path;
        }

        public void setComment(String comment) {
            this.comment = comment;
        }

        public void setContenttype(String contenttype) {
            this.contenttype = contenttype;
        }

        public void setRtype(String rtype) {
            this.rtype = rtype;
        }

        public void setNid(String nid) {
            this.nid = nid;
        }

        public void setTitle(String title) {
            this.title = title;
        }

        public void setType(String type) {
            this.type = type;
        }

        public void setImgs(List<String> imgs) {
            this.imgs = imgs;
        }



        public String getComment() {
            return comment;
        }

        public String getContenttype() {
            return contenttype;
        }

        public String getRtype() {
            return rtype;
        }

        public String getNid() {
            return nid;
        }

        public String getTitle() {
            return title;
        }

        public String getType() {
            return type;
        }

        public List<String> getImgs() {
            return imgs;
        }

        @Override
        public int getItemType() {
            return 0;
        }
    }

}
